/*
 * Licensed to the Apache Software Foundation (ASF) under one or more
 * contributor license agreements.  See the NOTICE file distributed with
 * this work for additional information regarding copyright ownership.
 * The ASF licenses this file to You under the Apache License, Version 2.0
 * (the "License"); you may not use this file except in compliance with
 * the License.  You may obtain a copy of the License at
 *
 *     http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
package cn.tedu.xuecha.server.repository;


import cn.tedu.xuecha.server.bo.ContentBO;

import cn.tedu.xuecha.server.protocol.param.ContentParam;
import cn.tedu.xuecha.server.protocol.query.ContentQuery;
import org.apache.ibatis.annotations.Mapper;
import org.springframework.stereotype.Repository;

import java.util.List;


public interface ContentRepository {
    /**
     * 插入内容表数据
     *
     * @param contentBO 内容表数据
     * @return 受影响的行数
     */
    Long insert(ContentBO contentBO);


    /**
     * 根据id删除内容表数据
     *
     * @param id 内容表id
     * @return 受影响的行数
     */
    int deleteById(Integer id);


    /**
     * 根据内容表id修改内容表的数据
     *
     * @param contentBO 封装了内容表id和新的数据的对象
     * @return 受影响的行数
     */
    int update(ContentBO contentBO);
//
//
//
//    /**
//     * 根据id查询内容表详情
//     *
//     * @param id 内容表id
//     * @return 匹配的内容表详情，如果没有匹配的数据，则返回null
//     */
//    ContentDBQuery getStandardById(Integer id);




    /**
     * 查询内容表列表
     *
     * @return 内容表列表
     */
    List<ContentQuery> list();


}